import axios from "axios";
const request = axios.create({
  //配置基础数据请求的路径
  baseURL: import.meta.env.VITE_APP_BASE_API,
});

// 用户列表接口
export function userdata(name, page = 10, size) {
  return request.post("/user/list/1/2", {
    name,
    page,
    size,
  });
}

export function orderdata() {
  return request.get("/afterSale/get/1", {});
}
export function orderdata2(cp, ls, orderIdkw, namekw, phonekw, status) {
  return request.post("/afterSale/list", {
    cp: "1",
    ls: "5",
    orderIdkw: "",
    namekw: "",
    phonekw: "",
    status: "7",
  });
}
export function orderdata3(cp, ls, orderIdkw, namekw, phonekw, status) {
  return request.post("/order/list", {
    cp: "1",
    ls: "5",
    orderIdkw: "",
    namekw: "",
    phonekw: "",
    status: "7",
  });
}
export function deleteOrder() {
  return request.delete("/user/delete/10003", {});
}
export function goodsList(cp=1, ls=5, namekw, status) {
  return request.post("/details/list", {
    cp,
    ls,
    namekw,
    status,
  });
}
